﻿<!DOCTYPE html>
<!--钢丝绳和吊钩检查表-->
<html>

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
        <script src="/static/js/common.js"></script>

    <style>
        body {
            padding-bottom: 10px;
        }

        .el-col {
            padding: 10px;
            font-size: 14px;
        }

        td {
            padding: 0 10px;
            font-size: 14px;
        }

        .el-form-item {
            margin-bottom: 0px !important;
        }

        .el-input-group__prepend{
            color: #000;
            font-size: 14px;
        }
        .el-input__inner {
            color: #606266;
            font-size: 14px;
        }

        .el-input-group__prepend {
            padding-left: 0
        }
    </style>
</head>

<body>
    
<div id="app" v-cloak>   
        <div style="width:100%;text-align:center ">
            <label style="font-weight:bold">钢丝绳和吊钩检查表</label>
        </div>

        <div style="width:100%;text-align:right ">
            <label>编号:{{Form.CheckNo}}</label>
        </div>
        <el-form :model="Form" status-icon style="margin-top:5px;width:100%" class="safeCard">
            <table style=" width:100%; border: 1px solid; " cellpadding="0" cellspacing="0">
                <tr>
                    <td width="33%" style="border-right:1px solid">
                        <div class="elst-select-mini">
                            <el-form-item>
                                <el-input size="mini">
                                    <template slot="prepend">
                                        <div>{{WireRopeAndHookCheck.Checker+mark.m}}</div>
                                    </template>
                                    <el-select @visible-change="visibleChange" v-model="Form.Checker" slot="suffix"
                                        :placeholder="WireRopeAndHookCheck.Checker">
                                        <el-option label="请选择" value=""></el-option>
                                        <el-option v-for="item in Checker" :label="item.value" :value="item.key">
                                        </el-option>
                                    </el-select>
                                </el-input>
                            </el-form-item>
                        </div>
                    </td>
                    <td width="33%" style="border-right:1px solid">
                        <el-form-item :label="WireRopeAndHookCheck.CheckDate+mark.m" class="inputTextarea">
                            <!-- 弹出页的其它不能成组的控件添加class="inputTextarea"，达到label与input、select等控件的label对齐的目的 -->
                            <el-date-picker v-model="Form.CheckDate" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
                                placeholder="选择日期">
                            </el-date-picker>
                        </el-form-item>
                    </td>
                    <td width="34%">
                        <div class="elst-select-mini">
                            <el-form-item>
                                <el-input type="text" v-model="Form.NumberPlate" autocomplete="off" size="mini">
                                    <template slot="prepend">
                                        {{WireRopeAndHookCheck.NumberPlate+mark.m}}
                                    </template>
                                </el-input>
                            </el-form-item>
                        </div>
                    </td>
                </tr>

            </table>
            <el-row style="border:1px  solid; border-top:0px ">
                <el-col :span="12" style="border-right:1px solid;">
                    <div class="elst-select-mini">
                        <el-form-item>
                            <el-input type="text" v-model="Form.UseUnit" autocomplete="off" size="mini">
                                <template slot="prepend">
                                    {{WireRopeAndHookCheck.UseUnit+mark.m}}
                                </template>
                            </el-input>
                        </el-form-item>
                    </div>
                </el-col>
                <el-col :span="12">
                    <div class="elst-select-mini">
                        <el-form-item>
                            <el-input size="mini">
                                <template slot="prepend">
                                    <div>{{WireRopeAndHookCheck.WorkingArea+mark.m}}</div>
                                </template>
                                <el-select @visible-change="visibleChange" v-model="Form.WorkingArea" slot="suffix"
                                    :placeholder="WireRopeAndHookCheck.WorkingArea">
                                    <el-option label="请选择" value=""></el-option>
                                    <el-option v-for="item in WorkingArea" :label="item.value" :value="item.key">
                                    </el-option>
                                </el-select>
                            </el-input>
                        </el-form-item>
                    </div>
                </el-col>
            </el-row>


            <el-row style="border:1px  solid;border-top:0px; text-align:center">
                <el-col span="24">
                    <label>{{WireRopeAndHookCheck.WireRopeHookCheck}}</label>
                </el-col>
            </el-row>

            <el-row style="border:1px  solid; border-top:0px;    ">
                <el-col :span="4" style="text-align:center">
                    {{WireRopeAndHookCheck.WireRopeInspectionProject}}
                </el-col>
                <el-col :span="5" style="border:1px  solid;border-top:0px;border-bottom:0px;text-align:center">
                    {{WireRopeAndHookCheck.Measureddiameter}}
                </el-col>
                <el-col :span="5"
                    style="border:1px  solid;border-top:0px;border-bottom:0px;border-left:0px; text-align:center">
                    {{WireRopeAndHookCheck.Brokenroot}}
                </el-col>
                <el-col :span="10" style="text-align:center">
                    {{WireRopeAndHookCheck.DamagedSituation}}
                </el-col>
            </el-row>
            <div v-for="todo in Form.ForearmWireRope">
                <el-row style="border:1px  solid; border-top:0px;    ">
                    <el-col :span="4" style="text-align:center">
                        {{WireRopeAndHookCheck.ForearmWireRope}}
                    </el-col>
                    <el-col :span="5" style="border:1px  solid;border-top:0px;border-bottom:0px;text-align:center">
                        <el-form-item>
                            <template>
                                <el-input-number v-model="todo.Measureddiameter" @change="handleChange" :min="1"
                                    size="mini"></el-input-number>
                            </template>
                        </el-form-item>
                    </el-col>
                    <el-col :span="5"
                        style="border:1px  solid;border-top:0px;border-bottom:0px;border-left:0px; text-align:center">
                        <el-form-item>
                            <el-input type="text" v-model="todo.Brokenroot" autocomplete="off" size="mini">
                            </el-input>
                        </el-form-item>
                    </el-col>
                    <el-col :span="10" style="text-align:center">
                        <el-form-item>
                            <el-input type="text" v-model="todo.DamagedSituation" autocomplete="off" size="mini">
                            </el-input>
                        </el-form-item>
                    </el-col>
                </el-row>
            </div>
            <div v-for="todo in Form.AuxiliaryArmWireRope">
                <el-row style="border:1px  solid; border-top:0px;    ">
                    <el-col :span="4" style="text-align:center">
                        {{WireRopeAndHookCheck.AuxiliaryArmWireRope}}
                    </el-col>
                    <el-col :span="5" style="border:1px  solid;border-top:0px;border-bottom:0px;text-align:center">
                        <el-form-item>
                            <template>
                                <el-input-number v-model="todo.Measureddiameter" @change="handleChange" :min="1"
                                    size="mini"></el-input-number>
                            </template>
                        </el-form-item>
                    </el-col>
                    <el-col :span="5"
                        style="border:1px  solid;border-top:0px;border-bottom:0px;border-left:0px; text-align:center">
                        <el-form-item>
                            <el-input type="text" v-model="todo.Brokenroot" autocomplete="off" size="mini">
                            </el-input>
                        </el-form-item>
                    </el-col>
                    <el-col :span="10" style="text-align:center">
                        <el-form-item>
                            <el-input type="text" v-model="todo.DamagedSituation" autocomplete="off" size="mini">
                            </el-input>
                        </el-form-item>
                    </el-col>
                </el-row>
            </div>
            <div v-for="todo in Form.MainArmWireRope">
                <el-row style="border:1px  solid; border-top:0px;    ">
                    <el-col :span="4" style="text-align:center">
                        {{WireRopeAndHookCheck.MainArmWireRope}}
                    </el-col>
                    <el-col :span="5" style="border:1px  solid;border-top:0px;border-bottom:0px; text-align:center">
                        <el-form-item>
                            <template>
                                <el-input-number v-model="todo.Measureddiameter" @change="handleChange" :min="1"
                                    size="mini"></el-input-number>
                            </template>
                        </el-form-item>
                    </el-col>
                    <el-col :span="5"
                        style="border:1px  solid;border-top:0px;border-bottom:0px;border-left:0px; text-align:center">
                        <el-form-item>
                            <el-input type="text" v-model="todo.Brokenroot" autocomplete="off" size="mini">
                            </el-input>
                        </el-form-item>
                    </el-col>
                    <el-col :span="10" style="text-align:center">
                        <el-form-item>
                            <el-input type="text" v-model="todo.DamagedSituation" autocomplete="off" size="mini">
                            </el-input>
                        </el-form-item>
                    </el-col>
                </el-row>
            </div>

            <el-row style="border:1px  solid;border-top:0px; text-align:center">
                <el-col span="24">
                    <label>{{WireRopeAndHookCheck.HookInspectionProject}}</label>
                </el-col>
            </el-row>

            <el-row style="border:1px  solid; border-top:0px;    ">
                <el-col :span="4" style="text-align:center">
                    {{WireRopeAndHookCheck.HookInspectionProject}}
                </el-col>
                <el-col :span="5" style="border:1px  solid;border-top:0px;border-bottom:0px; text-align:center">
                    {{WireRopeAndHookCheck.MeasuredOpeningSize}}
                </el-col>
                <el-col :span="5"
                    style="border:1px  solid;border-top:0px;border-bottom:0px;border-left:0px; text-align:center">
                    {{WireRopeAndHookCheck.Diameter}}
                </el-col>
                <el-col :span="5"
                    style="border:1px  solid;border-top:0px;border-bottom:0px;border-left:0px; text-align:center">
                    {{WireRopeAndHookCheck.IsThereSafetyPin}}
                </el-col>
                <el-col :span="5" style="text-align:center">
                    {{WireRopeAndHookCheck.WhetherDeformation}}
                </el-col>
            </el-row>
            <div v-for="todo in Form.MainHook">
                <el-row style="border:1px  solid; border-top:0px;    ">
                    <el-col :span="4" style="text-align:center">
                        {{WireRopeAndHookCheck.MainHook}}
                    </el-col>
                    <el-col :span="5"
                        style="border:1px  solid;border-top:0px;border-bottom:0px; text-align:center;height:40px">
                        <el-form-item>
                            <template>
                                <el-input-number v-model="todo.MeasuredOpeningSize" @change="handleChange" :min="1"
                                    size="mini"></el-input-number>
                            </template>
                        </el-form-item>
                    </el-col>
                    <el-col :span="5"
                        style="border:1px  solid;border-top:0px;border-bottom:0px;border-left:0px; text-align:center;height:40px">
                        <el-form-item>
                            <template>
                                <el-input-number v-model="todo.Diameter" @change="handleChange" :min="1" size="mini">
                                </el-input-number>
                            </template>
                        </el-form-item>
                    </el-col>
                    <el-col :span="5"
                        style="border:1px  solid;border-top:0px;border-bottom:0px;border-left:0px; text-align:center ;height:40px">
                        <el-form-item>
                            <el-radio-group v-model="todo.IsThereSafetyPin">
                                <el-radio v-for="item in IsDevelopSafetyPlan" :label="item.value" :value="item.key">
                                    {{item.value}}</el-radio>
                            </el-radio-group>
                        </el-form-item>
                    </el-col>
                    <el-col :span="5" style="text-align:center ;height:40px">
                        <el-form-item>
                            <el-radio-group v-model="todo.WhetherDeformation">
                                <el-radio v-for="item in IsDevelopSafetyPlan" :label="item.value" :value="item.key">
                                    {{item.value}}</el-radio>
                            </el-radio-group>
                        </el-form-item>
                    </el-col>
                </el-row>
            </div>
            <div v-for="todo in Form.AuxiliaryHook">
                <el-row style="border:1px  solid; border-top:0px;height:40px">
                    <el-col :span="4" style="text-align:center">
                        {{WireRopeAndHookCheck.AuxiliaryHook}}
                    </el-col>
                    <el-col :span="5"
                        style="border:1px  solid;border-top:0px;border-bottom:0px; text-align:center ;height:40px">
                        <el-form-item>
                            <template>
                                <el-input-number v-model="todo.MeasuredOpeningSize" @change="handleChange" :min="1"
                                    size="mini"></el-input-number>
                            </template>
                        </el-form-item>
                    </el-col>
                    <el-col :span="5"
                        style="border:1px  solid;border-top:0px;border-bottom:0px;border-left:0px; text-align:center ;height:40px">
                        <el-form-item>
                            <template>
                                <el-input-number v-model="todo.Diameter" @change="handleChange" :min="1" size="mini">
                                </el-input-number>
                            </template>
                        </el-form-item>
                    </el-col>
                    <el-col :span="5"
                        style="border:1px  solid;border-top:0px;border-bottom:0px;border-left:0px; text-align:center;height:40px">
                        <el-form-item>
                            <el-radio-group v-model="todo.IsThereSafetyPin">
                                <el-radio v-for="item in IsDevelopSafetyPlan" :label="item.value" :value="item.key">
                                    {{item.value}}</el-radio>
                            </el-radio-group>
                        </el-form-item>
                    </el-col>
                    <el-col :span="5" style="text-align:center ;height:40px">
                        <el-form-item>
                            <el-radio-group v-model="todo.WhetherDeformation">
                                <el-radio v-for="item in IsDevelopSafetyPlan" :label="item.value" :value="item.key">
                                    {{item.value}}</el-radio>
                            </el-radio-group>
                        </el-form-item>
                    </el-col>
                </el-row>
            </div>
            <el-row>
                <el-form-item style="text-align:center; padding-top:5px">
                    <el-button type="primary" @click="parent.ListItem.dialogVisible=false">{{col.btnBack}}</el-button>
                </el-form-item>
            </el-row>
        </el-form>
        <el-dialog title="" :visible.sync="ListItem.dialogVisible" width="90%" height="95%" top="10vh">
            <iframe ref="iframe" :src="ListItem.InputUrl" style="height:95%;width:100%" frameborder="0"></iframe>
        </el-dialog>
    </div>
    <script type="text/javascript">
        app = new Vue({
            el: '#app',
            data: {
                id: '',
                Form: {
                    id: guidEmpty,
                    Checker: '',// "检查人",
                    Checkdate: '',//  "时间",
                    CheckNo: '',
                    numberPlate: '',// "车牌号",
                    UseUnit: '',// "使用单位",
                    WorkingArea: '',// "作业区域",
                    WireRopeHookCheck: '',// "钢丝绳和吊钩检查表",
                    WireRopeInspectionProject: '',// "钢丝绳检查项目",
                    Measureddiameter: '',// "实测直径mm",
                    Brokenroot: '',// "断丝根",
                    DamagedSituation: '',//  "受损情况",
                    ForearmWireRope: '',//  "前臂钢丝绳",
                    AuxiliaryArmWireRope: '',//  "副臂钢丝绳",
                    MainArmWireRope: '',// "主臂钢丝绳",
                    HookInspectionProject: '',// "吊钩检查项目",
                    MeasuredOpeningSize: '',// "实测开口尺寸mm",
                    Diameter: '',//  "直径mm",
                    IsThereSafetyPin: '',//  "是否有安全销",
                    WhetherDeformation: '',//  "是否变形",
                    MainHook: '',// "主钩",
                    AuxiliaryHook: '',// "辅钩"
                },
                TerritorialDepartment: [],
                IsDevelopSafetyPlan: [],
                WorkingArea: [],
                Checker: [],
                rules: {},
                BasedDatabaseManagementRequirements: [],
                ListItem: ListItem,
            },
            methods: {
                //解決edge下select bug
                visibleChange: function (isVisible) {
                    visibleChange(isVisible)
                },
                handleNodeClick: function (data) {
                    console.log(data);
                },
                handleChange: function (value) {
                    console.log(value);
                },
                handleChecked: function (value) {
                },
                handleCheckedConfirmation: function (value) {
                },
                deleteRow: function (index, rows) {
                    rows.splice(index, 1);
                },
                getData: function () {
                    getDataAdd(this, '/api/WireRopeAndHookCheck/get?id=' + this.id);
                },
                Bianji: function (val, id) { DialogShow(this, val, "RelatedTableList.html", id); },

                UserInput: function (val, id) { DialogShow(this, val, "HoistingGuardianInput.html", id); },
                ApproverInput: function (val, id) { DialogShow(this, val, "ApproverInput.html", id); },
                LiftingOperatorInput: function (val, id) { DialogShow(this, val, "LiftingOperatorInput.html", id); },
                RiskInformationBase: function (val, id) {
                    DialogShow(this, val, "RiskInformationBase.html", id);
                },
                //提交数据
                onSubmitForm: function (formName) {
                    var mythis = this;
                    //this.$refs[formName].validate(function (valid) {
                    //    //验证通过
                    //    if (valid) {
                    onSubmitForm(this, '/api/WireRopeAndHookCheck/Save', mythis.Form);
                    //} else {
                    //    //验证失败
                    //    return false;
                    //}
                    //});
                },
            },
            mounted: function () {
                var list = getDicDataArray(['08', '50', '97', '09']);
                this.TerritorialDepartment = getDicDatafromArray('08', list);//工作类型
                this.IsDevelopSafetyPlan = getDicDatafromArray('50', list);//工作类型
                this.WorkingArea = getDicDatafromArray('97', list);//
                this.Checker = getDicDatafromArray("09", list);//批准人
                this.id = getUrlParam("id");
                this.getData();
                //this.BasedDatabaseManagementRequirements = this.Form.BasedDatabaseManagementRequirements;
            }
        });
    </script>
</body>

</html>